using System;
using System.Collections.Generic;
using System.Reflection;
using System.Runtime.CompilerServices;

namespace ClownFish
{
	public static class MyExtensions
	{
		[CompilerGenerated]
		private sealed class Class1
		{
			public string string_0;

			public bool method_0(string string_1)
			{
				return string.Compare(string_1, this.string_0, StringComparison.OrdinalIgnoreCase) == 0;
			}
		}

		[CompilerGenerated]
		private sealed class Class2
		{
			public string string_0;

			public bool method_0(string string_1)
			{
				return string.Compare(string_1, this.string_0, StringComparison.OrdinalIgnoreCase) == 0;
			}
		}

		public static T GetAttribute<T>(this MemberInfo memberInfo_0) where T : Attribute
		{
			T[] array = memberInfo_0.GetCustomAttributes(typeof(T), false) as T[];
			if (array.Length == 1)
			{
				return array[0];
			}
			return default(T);
		}

		public static T[] GetAttributes<T>(this MemberInfo memberInfo_0) where T : Attribute
		{
			return memberInfo_0.GetCustomAttributes(typeof(T), false) as T[];
		}

		public static int FindIndex(this string[] array, string value)
		{
            try
            {
                MyExtensions.Class1 @class = new MyExtensions.Class1();
                @class.string_0 = value;
                return Array.FindIndex<string>(array, new Predicate<string>(@class.method_0));
            }
            catch (Exception ex)
            {
                return -1;
            }
			
		}

		public static int FindIndex(this List<string> list, string value)
		{
			MyExtensions.Class2 @class = new MyExtensions.Class2();
			@class.string_0 = value;
			return list.FindIndex(new Predicate<string>(@class.method_0));
		}
	}
}
